Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes for the tax2gas implementation and gas handling
Copilot Summary
This pull request introduces a new
Tax2Gas
feature to the Terra application, which includes significant changes to the handling of gas consumption and taxation. The most important changes include the addition of theTax2GasMeter
for gas metering, the implementation of new decorators and handlers, and the adjustment of existing code to integrate with the newTax2Gas
system.Integration of Tax2Gas Feature:
New Gas Meter Implementation:
Tax2GasMeter
to handle gas consumption and taxation (x/tax2gas/types/gas.go
).New Ante and Post Handlers:
Tax2GasDecorator
andGasRegisterDecorator
to manage gas limits and register gas in the context (x/tax2gas/keeper/ante.go
).Tax2gasPostDecorator
to useTax2GasMeter
for post-transaction gas handling (x/tax2gas/post/post.go
). [1] [2] [3] [4]Context and Gas Handling Adjustments:
DispatchMsg
method to integrateTax2GasMeter
(custom/wasm/keeper/handler_plugin.go
). [1] [2]AnteHandle
method to utilizeTax2GasMeter
for gas consumption (x/tax2gas/ante/ante.go
). [1] [2]Configuration and Testing:
Configuration Changes:
go.mod
to update thecosmos-sdk
dependency (go.mod
).Testing Enhancements:
Tax2GasMeter
in various test files (wasmbinding/test/tax_test.go
,x/tax2gas/ante/ante_test.go
,x/tax2gas/ante/fee_test.go
). [1] [2] [3] [4]Code Cleanup:
Tax2GasDecorator
(custom/auth/ante/ante.go
).These changes collectively introduce the
Tax2Gas
functionality, enhancing the gas management system within the Terra application.